﻿#ifndef LOGIN_H
#define LOGIN_H

#include <QWidget>
#include <QTcpSocket>
#include <QHostAddress>
#include <QMessageBox>
#include "register.h"
#include "sqlite.h"
#include <QPainter>
#include <QPaintEvent>
namespace Ui {
class Login;
}

class Login : public QWidget
{
    Q_OBJECT

public:
    explicit Login(QWidget *parent = nullptr);
    ~Login();

public:
    void paintEvent(QPaintEvent *event);
signals:
    void sendLoginSuccess();

private slots:
    void on_pb_login_clicked();

    void on_pb_reg_clicked();

private:
    Ui::Login *ui;
    QTcpSocket *socket;
    Register m_register;
    Sqlite *m_ptrSql;

};

#endif // LOGIN_H
